package com.css.casualties.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.css.casualties.entity.RyswModel3Data;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

import java.util.List;

/**
 * @author Dbj
 * @date 2024年09月14日  9:36
 */
@Mapper
public interface RyswModel3DataMapper extends BaseMapper<RyswModel3Data> {
    @Select("select *,st_astext(ST_Intersection(geom, ST_GeomFromText(#{geomText}, 4490))) as geomText from basic_rysw_model3_data where intensity=#{intensity} and ST_Intersects(geom, ST_GeomFromText(#{geomText}, 4490))")
    List<RyswModel3Data> getDataByGeom(@Param("intensity") String intensity, @Param("geomText") String geom);
}
